/**
 *  GPR2Location.java : IceBird project
 *  23:49:26 
 */
package icebird.compiler.ncomp.vs;

import icebird.compiler.ncomp.X86Register.GPR;

/**
 * Used to describe double word on 32bit machine.
 * @author Sergey Shulepoff[Knott]
 */
public final class GPR2Location extends Location {

	private GPR lsb;
	private GPR msb;
	
	
	/**
	 * @param lsb
	 * @param msb
	 */
	public GPR2Location(GPR lsb, GPR msb) {
		super("GPR2: " + lsb + ":" + msb);
		this.lsb = lsb;
		this.msb = msb;
	}


	/**
	 * @return the lsb
	 */
	public GPR getLW() {
		return lsb;
	}


	/**
	 * @param lsb the lsb to set
	 */
	public void setLW(GPR lsb) {
		this.lsb = lsb;
	}


	/**
	 * @return the msb
	 */
	public GPR getHW() {
		return msb;
	}


	/**
	 * @param msb the msb to set
	 */
	public void setHW(GPR msb) {
		this.msb = msb;
	}


	/* (non-Javadoc)
	 * @see icebird.compiler.ncomp.vs.Location#getWeight()
	 */
	public int getWeight() {
		return 2; // 2 registers.
	}
}
